package com.example.web;

import com.example.mapper.RemoveAllMapper;
import com.example.utils.Message;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

//期末删除数据 包含 考核表 ，公告表 ， 保修表 ， 缴费表 ， 换寝申请
@RequestMapping("/removeAll")
@RestController
public class RemoveAll {

    @Autowired
    private RemoveAllMapper removeAllMapper;

    @RequestMapping("/all")
    public Message remove() {
        boolean b0 = removeAllMapper.removeAssess();
        boolean b1 = removeAllMapper.removeCost();
        boolean b2 = removeAllMapper.removeLost();
        boolean b3 = removeAllMapper.removeNotice();
        boolean b4 = removeAllMapper.removeRepair();
        boolean b5 = removeAllMapper.removeTrade();
        boolean b6 = removeAllMapper.removeChat();
        return Message.out(200, "删除全部记录数据", b0 && b1 && b2 && b3 && b4 && b5 && b6);
    }


}
